home *** CD-ROM | disk | FTP | other *** search
/ ftp.cs.arizona.edu / ftp.cs.arizona.edu.tar / ftp.cs.arizona.edu / icon / newsgrp / group00a.txt / 000082_icon-group-sender _Mon May 1 21:00:51 2000.msg < prev    next >
Internet Message Format  |  2001-01-03  |  3KB

  1. Return-Path: <icon-group-sender>
  2. Received: (from root@localhost)
  3.     by baskerville.CS.Arizona.EDU (8.9.1a/8.9.1) id UAA10001
  4.     for icon-group-addresses; Mon, 1 May 2000 20:58:42 -0700 (MST)
  5. Message-Id: <200005020358.UAA10001@baskerville.CS.Arizona.EDU>
  6. Date: Fri, 28 Apr 2000 12:31:31 +1200 (NZST)
  7. From: "Richard A. O'Keefe" <ok@atlas.otago.ac.nz>
  8. To: NOSPAM.Frank.Lhota@lexma.meitech.com, icon-group@optima.CS.Arizona.EDU
  9. Subject: Re: Is Anyone Working On A Unicode Version Of Icon?
  10. Errors-To: icon-group-errors@optima.CS.Arizona.EDU
  11. Status: RO
  12.  
  13. "Frank J. Lhota" <NOSPAM.Frank.Lhota@lexma.meitech.com> wrote:
  14. > We may, unfortunately, be at a point where this is too late to change the
  15. > predefined csets. ... The right fix might be to add new prefined csets,
  16. > so that new code could be properly internationalized.
  17.     
  18. May I suggest instead new *functions* for getting csets?
  19.     lower_case_cset(Locale) -> Cset
  20.     upper_case_cset(Locale) -> Cset
  21.     title_case_cset(Locale) -> Cset
  22.     letter_cset(Locale) -> Cset
  23. and so on, where a Locale could be a string such as "en_NZ".    
  24.  
  25. > If we were to use the packed array of bits approach for wide characters, a
  26. > cset would be represented by 2048 words -- Yikes! Clearly, we would need to
  27. > use a different internal representation.
  28.  
  29. It's worse than that.  One of the core design principles of Unicode was
  30. that it coded characters, not languages; language tagging was supposed to
  31. be left to a higher-level protocol.  Well, that's not true in Unicode 3.0
  32. any more.  There are language markup tags in Plane 14.  Now 2048 words is
  33. enough for one plane...  Plane 0 is now pretty much full, and useful stuff
  34. is going in Plane 1, so the age of 16 bit characters didn't really last
  35. very long.
  36.  
  37. > I would suggest representing a cset as an ordered list  of character
  38. > intervals. ... Most csets that actually occur in
  39. > applications, however, could be represented by a handful of intervals.
  40.     
  41. Not unless you have rather large hands.
  42. I just ran a little AWK script against unidata2.txt (I don't have
  43. the Unicode 3.0 version yet), and found
  44.  
  45.     DIGIT         22 intervals
  46.     LETTER        179 intervals
  47.     CAPITAL LETTER    337 intervals
  48.     SMALL LETTER    349 intervals
  49.  
  50. I suspect that letter csets will be wanted rather often.
  51. Perhaps a hybrid representation might be better:
  52.  - a bitmap for the first 256 characters of Unicode
  53.  - a "window pointer" selecting another block of 256 characters,
  54.    so that the current locale (Cyrillic, or Greek, or Arabic, or whatever)
  55.    can be accessed fairly fast
  56.  - a bitmap for the characters in the selected window
  57.  - an ordered list of intervals for the remaining characters
  58.  
  59.